module half_adder (
    input      a,
    input      b,
    output reg cout,
    output reg sum
);
  always @(a, b) begin
    cout <= a & b;
    sum  <= a ^ b;
  end
endmodule
